﻿using Newtonsoft.Json;
using System;
using System.Collections.Generic;
using System.Text;

namespace Common.Wechat
{
    public abstract class MediaPlatformModelBase
    {
        [JsonProperty("errcode")]
        public string ErrorCode { get; set; }
        [JsonProperty("errmsg")]
        public string ErrorMsg { get; set; }
        [JsonProperty("expires_in")]
        public int Expires { get; set; }
        public TimeSpan GetExpires()
        {
            return TimeSpan.FromSeconds(this.Expires - 10);
        }
    }
}
